import java.awt.Image;
import java.util.*;


public class Player {
	Game game;
	String data;
	int location;
	boolean isTurn;
	GameBoard board;
	int score = 0;
	static int id;
	
	public Player(int i) {
		id = i;
	}
	
	public void toggleTurn() {
		// We probably want to add in some nice turn changin' code here
		isTurn = !isTurn;
	}
	
	public void run() {
		if(isTurn) {
			Game[] temp = board.getGames();
			// We probably should add a button later
			int dist = (location + (int)(new Random().nextDouble() * 6)) - location;
			board.movePiece(dist, true);		
			game = temp[dist + location];
			board.setGame(game, true);
		}
	}
	
	public void increaseScore(int i) {
		score += i;
	}
	
	public void setBoard(GameBoard b) {
		board = b;
	}
	
	// This does all that graffix jank
	public Image disp(Image img) {
		return null;
	}
	
}
